﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.Master" AutoEventWireup="true"
    CodeBehind="KhoHang.aspx.cs" Inherits="XuaNhapKho.KhoHang" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div class="breadLine">
        <ul class="breadcrumb">
            <li><a href="#">Quản lý xuất nhập kho</a> <span class="divider">></span></li>
            <li class="active">Nhập kho</li>
        </ul>
    </div>
    <div class="workplace">
        <div class="row-fluid">
            <div class="span12">
                <div class="wBlock red auto">
                    <div class="dSpace">
                        <h3>
                            Số lượng hàng trong kho</h3>
                        <span class="mChartBar" sparktype="bar" sparkbarcolor="white">
                            <!--2,5,3,5,6,7,9,8,5,6,2,5-->
                        </span><span class="number">
                            <asp:Literal ID="ltlTongHang" runat="server"></asp:Literal>
                        </span>
                    </div>
                </div>
                <div class="wBlock green auto">
                    <div class="dSpace">
                        <h3>
                            Tông tiền</h3>
                        <span class="mChartBar" sparktype="bar" sparkbarcolor="white">
                            <!--5,10,15,20,23,21,25,20,15,10,25,20,10-->
                        </span><span class="number">
                            <asp:Literal ID="ltlTongTienKho" runat="server"></asp:Literal> VND</span>
                    </div>
                </div>
                
            </div>
        </div>
        <div class="row-fluid">
            <div class="span12">
                <div class="head">
                    <div class="isw-grid">
                    </div>
                    <h1>
                        Tìm kiếm kho hàng</h1>
                    <div class="clear">
                    </div>
                </div>
                <div class="block">
                    Tìm kiếm theo mã hàng
                    <asp:TextBox ID="txtMaSanPham" runat="server"></asp:TextBox>
                   
                    <asp:Button ID="btnSearch"  CssClass="btn" 
                        style="height : 30px; margin-top: -7px;" runat="server" 
                        Text="Tìm kiếm theo mã" onclick="btnSearch_Click" 
                        />
                </div>
            </div>
        </div>
        <div class="row-fluid">
            <div class="span12">
                <div class="head">
                    <div class="isw-grid">
                    </div>
                    <h1>
                        Danh sách kho</h1>
                    <div class="clear">
                    </div>
                </div>
                <div class="block-fluid">
                    <asp:GridView ID="grvKho"  BorderStyle="None" GridLines="None"  
                        CssClass="table" runat="server" AutoGenerateColumns="False" AllowPaging="True" 
                        onpageindexchanging="grvKho_PageIndexChanging">
                        <Columns>
                            <asp:BoundField DataField="MaSanPham" HeaderText="Mã hàng" />
                            <asp:BoundField DataField="TenSanPham" HeaderText="Tên sản phẩm" />
                            <asp:BoundField DataField="TenNhomSanPham" HeaderText="Nhóm sản phẩm" />
                            <asp:BoundField DataField="TenDonVi" HeaderText="Đơn vị tính" />
                            <asp:BoundField DataField="SoLuong" HeaderText="Số lượng" />
                            <asp:TemplateField HeaderText="Đơn giá">
                                <ItemTemplate>
                                    <%# String.Format("{0:0,0}",Double.Parse(Eval("GiaSanPham").ToString()))  %>
                                </ItemTemplate>
                            </asp:TemplateField>
                         
                            <asp:TemplateField HeaderText="Ngày nhập">
                                <ItemTemplate>
                                    <asp:Label ID="Label1" runat="server" Text='<%# Eval("NgayTao","{0:dd/MM/yyyy | HH:mm}") %>'></asp:Label>
                                </ItemTemplate>
                                
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                </div>
            </div>
        </div>
    </div>
</asp:Content>
